{% extends "../layout/layout.html" %} {% block main %}
<div class="container">
  <div class="row">
    {% if error  %}
    <div class="alert alert-danger alert-dismissible" role="alert">
      <button
        type="button"
        class="close"
        data-dismiss="alert"
        aria-label="Close"
      >
        <span aria-hidden="true">&times;</span>
      </button>
      {{error}}
    </div>
    {% endif %}
    
    <div class="col-md-6 col-md-offset-3">
      <form class="form-horizontal" action="login" method="post">
        <div class="form-group">
          <label for="username" class="col-sm-2 control-label">用户名:</label>
          <div class="col-sm-10">
            <input
              type="text"
              class="form-control"
              name="username"
              id="username"
              placeholder="请输入用户名"
            />
          </div>
        </div>
        <div class="form-group">
          <label for="password" class="col-sm-2 control-label">密码:</label>
          <div class="col-sm-10">
            <input
              type="password"
              class="form-control"
              name="password"
              id="password"
              placeholder="请输入密码"
            />
          </div>
        </div>
        <div class="form-group">
          <div class="col-sm-offset-2 col-sm-10">
            <button type="submit" class="btn btn-default">登 录</button>
          </div>
        </div>
      </form>
    </div>
  </div>
</div>
{% endblock %}
